import request from '@/utils/request';

import axios from 'axios';

export function getUnresolveMessageList() {
    return request({
        url: '/bank-financing/getUnresolveMessageList.do',
        method: 'post'
    });
}

export function deleteUpoladMessage(filename) {
    return request({
        url: `/bank-financing/deleteUpoladMessage.do/${filename}`,
        method: 'delete'
    });
}

export function startResolveMessage() {
    return request({
        url: '/bank-financing/startResolveMessage.do',
        method: 'post'
    });
}

export function checkResolveMessageStatus() {
    return request({
        url: '/bank-financing/checkResolveMessageStatus.do',
        method: 'post'
    });
}
export function getInfo(pageInfo) {
    return request({
        url: '/bank-financing/getInfo.do',
        method: 'post',
        data: pageInfo
    });
}

export function validateInfo(month) {

    // return request({
    //     responseType: 'blob',
    //     url: `/bank-financing/validateInfo.do/${month}`,
    //     method: 'get'
    // })
    return axios({
        baseURL: process.env.BASE_URL,
        method: 'get',
        url: `/bank-financing/validateInfo.do/${month}`,
        responseType: 'blob',
    });
}
